MS Access, Information

Start Options

File / Open / Options/ Current Data Base

· Application Title

· Display Form ( Default Form)

· Display Status Bar

· Windows ( Overlapping, Tabbed )

· Enable ( Views, layout, Design, etc. )

· Display Navigation (more Options )

Posted by editor

Left, Right, Len, Trim

SELECT store.full, InStr([full],”-“) AS dash, instr(full, “,”) as comma, Left([full],dash-1) AS StoreNum, mid(full,dash + 1 , comma – dash – 1) AS city, trim( right( full, len(full) – comma)) as state
FROM store;

Posted by editor


INSERT INTO Customers1
SELECT Customers0.[Company] AS Company, Customers0.[LastName] AS LastName, firstn AS firstName, 1 AS selected
FROM Customers0;

Posted by editor

VBA Recordset
VBA Recordset: How to Handle Sets of Records Easily


Visual Basic for Applications or VBA is an important event driven programming language. It is used for creating programs which enhance the Microsoft Office suite of applications. Visual Basic for Applications is perfect for developing specific applications, whether these are office resources, graphics programs, file sorting programs, or any other kind of Windows-based software programs. Today we look at the useful and frequently used Recordset function, in this intermediate level tutorial. You require a basic level of familiarity with Microsoft Access. If you’re new to them, you should first do this introductory course to Microsoft Access. For folks who are familiar with VBA, you can just do a quick brush up with this VBA tutorial.
Continue reading →

Posted by editor

Walkthrough: Writing Queries in Visual Basic

Visual Studio 2015

This walkthrough demonstrates how you can use Visual Basic language features to write Language-Integrated Query (LINQ) query expressions. The walkthrough demonstrates how to create queries on a list of Student objects, how to run the queries, and how to modify them. The queries incorporate several features that were new in Visual Basic 2008, including object initializers, local type inference, and anonymous types.

After completing this walkthrough, you will be ready to move on to the samples and documentation for the specific LINQ provider you are interested in. LINQ providers include LINQ to SQL, LINQ to DataSet, and LINQ to XML.
Continue reading →

Posted by editor


Public Sub DoSQL()

Dim SQL As String

SQL = “UPDATE Employees ” & _

“SET Employees.Title = ‘Regional Sales Manager’ ” & _

“WHERE Employees.Title = ‘Sales Manager'”


End Sub

Posted by editor


Dim sqlConnection1 As New SqlConnection(“Your Connection String”)

Dim cmd As New SqlCommand

Dim reader As SqlDataReader

cmd.CommandText = “SELECT * FROM Customers”

cmd.CommandType = CommandType.Text

cmd.Connection = sqlConnection1

reader = cmd.ExecuteReader()
‘ Data is accessible through the DataReader object here.

Posted by editor


There are three main types of SQL-specific query: union queries, pass-through queries, and data-definition queries.

Union queries combine data from two or more tables, but not in the same manner as other queries. Whereas most queries combine data by concatenating rows, union queries combine data by appending rows. Union queries differ from append queries in that union queries do not change the underlying tables. Union queries append the rows in a recordset that does not persist after the query is closed.

Pass-through queries are not processed by the database engine that comes with Access; rather, they are passed directly to a remote database server that does the processing and then passes the results back to Access.

Data-definition queries are a special type of query that does not process data; instead, data-definition queries create, delete or modify other database objects.

SQL-specific queries cannot be opened in Design view. They can only be opened in SQL view, or run. Except for data-definition queries, running a SQL-specific query opens it in Datasheet view.

Posted by editor