CAST/CONVERT function in Access
There is no CAST/CONVERT function in Access. But you can find a few equivalents for the convertion functions. For example: Cint(x)–CONVERT(smallint,x) Clng(x)–CONVERT(int,x) Cstr(x)–CONVERT(varchar,x)...
View ArticleAdd an AutoNumber column as primary key field in Access (2003/7) through DDL
Here is the syntax: Alter TABLE XYZAdd column myID COUNTER CONSTRAINT PrimaryKey PRIMARY KEY If we want to set the seed for the AutoNumber field, we can run this query:alter table XYZalter column...
View ArticleEditing for GridView and DetailsView with Access 2007
Here is a sample gridview and detailsview with editing capability with Access 2007 data. The key is to connect to the Access 2007 database table. Connection string in your webconfig:...
View ArticleSwitch function in Access
Today i came across Switch function for a forum question. The user wants to sort his Month column in right order instead of alphabetically. It would be easy to do this in SQL Server with CASE...
View Article