loading
 
SQL_Interface fails INSERT INTO
Bongo from Burma  [2 posts]
5 year
Dear RR team,

I downloaded your trial to check the creation of a smart barrier. The RR part should be reading the license plates of the vehicles. That I kind of did. The problem comes when I want to export the data to a MySQL server I created locally. The connection is OK but I get a syntaxt error which I'm pretty sure it's false. The screen's code is:
insert into vehicle_movement (vehicle_movement_id) values ([PLATE_NUMBER])

Although I tried with ''s and "<db>." and everything I thought might cause this.

Just the RR Error Text makes no sense: "Unknown column 'CA1077PB' in 'field list'."

The error # 42S22 is general MySQL error but no RR related help I found on Google. :(

    
Steven Gentner from United States  [1446 posts] 5 year
For literal values you may need to include quotes around the value:

insert into vehicle_movement (vehicle_movement_id) values ("[PLATE_NUMBER]")

STeven.
Bongo from Burma  [2 posts] 5 year
Thank you Steven!

Actually it worked with '[PLATE_NUMBER]' . Turned out MySQL syntax is how it works with String values. All strings should be in ' '.

P.S. - Slightly different issue but the 'date' symbols in [CLOCK_DATETIME] are bugged. Sending them to MySQL goes as 2 squares. Not a big deal though, I do CURRENT_TIMESTAMP generation in MySQL.

This forum thread has been closed due to inactivity (more than 4 months) or number of replies (more than 50 messages). Please start a New Post and enter a new forum thread with the appropriate title.

 New Post   Forum Index