| |

VerySource

 Forgot password?
 Register
Search
View: 806|Reply: 4

The master helped me look at the SQL statement, thank you

[Copy link]

4

Threads

19

Posts

17.00

Credits

Newbie

Rank: 1

Credits
17.00

 China

Post time: 2020-1-5 17:50:01
| Show all posts |Read mode
adoquery1.SQL.Clear;
adoquery1.SQL.Add ('select table1.id as automatic numbering, table1.company as company code, table1.barcode as bar code, table1.liushui as flow code, table1.inout as cargo status, table1.datetime as date from table1 WHERE TABLE1.COMPANY = '"+ edit1.text +"');
adoquery1.ExecSQL;
adoquery1.active: = true;

Why did it report an error?
Reply

Use magic Report

0

Threads

15

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

Post time: 2020-1-6 00:45:01
| Show all posts
adoquery1.SQL.Add ('select table1.id as automatic numbering, table1.company as company code, table1.barcode as bar code, table1.liushui as flow code, table1.inout as cargo status, table1.datetime as date from table1 WHERE TABLE1.COMPANY = '+ # 39 + edit1.text + # 39);

Also, it ’s better not to use Chinese characters
Reply

Use magic Report

0

Threads

15

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 Localhost

Post time: 2020-1-6 00:57:02
| Show all posts
adoquery1.ExecSQL;
Don't say this
Reply

Use magic Report

4

Threads

19

Posts

17.00

Credits

Newbie

Rank: 1

Credits
17.00

 China

 Author| Post time: 2020-1-6 01:06:01
| Show all posts
Oh, I want to display Chinese in DBGRID ~~ Do you have any other methods?
Reply

Use magic Report

0

Threads

15

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

Post time: 2020-1-6 09:45:01
| Show all posts
DBGRID shows Chinese can be directly entered in the column properties
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

Contact us|Archive|Mobile|CopyRight © 2008-2023|verysource.com ( 京ICP备17048824号-1 )

Quick Reply To Top Return to the list