Click here to Skip to main content
15,886,055 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi.
I have a sqlite column type of real in a table and I want to know which DbType should I use in C# for real columns.
My need is adding a new parameter for a sqlite command.
just like this.
C#
cmd.Parameters.Add("@_param", DbType.??);

Thanks in advance.
Posted

1 solution

That will be REAL[^]
more: Datatypes In SQLite[^]
+++++[Edit]+++++
According to https://msdn.microsoft.com/en-us/library/cc716729%28v=vs.110%29.aspx
That would be Single.
 
Share this answer
 
v3
Comments
M­­ar­­­­k 13-Feb-15 23:39pm    
I dont see a real in DbType enum. :(
https://msdn.microsoft.com/en-us/library/system.data.dbtype(v=vs.110).aspx
Garth J Lancaster 13-Feb-15 23:52pm    
why are you referring to Microsoft documentation if you're dealing with a SQLite Database ?
M­­ar­­­­k 14-Feb-15 23:08pm    
Its because Parameters.Add function uses DbType enum.
Peter Leow 15-Feb-15 0:35am    
According to https://msdn.microsoft.com/en-us/library/cc716729%28v=vs.110%29.aspx
That would be Single.
M­­ar­­­­k 15-Feb-15 5:56am    
Thanks :)
Can u please post this as a solution so I can accept it. :)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900