WHERE, LIKE - are filters
Relational Operators - use to evaluate if the condition is true
>
<
<>
>=
<=
=
Array:
Dim strSQLStrings() As String = {"SELECT * FROM ApprovedTravelRequests", _
"SELECT [Travel Cost]FROM ApprovedTravelRequests", _
"SELECT [Travel Cost], [Location] FROM ApprovedTravelRequests", _
"SELECT * FROM ApprovedTravelRequests WHERE Location = 'Richmond, VA'", _
"SELECT * FROM ApprovedTravelRequests WHERE Location LIKE 'R%'", _
"SELECT * FROM ApprovedTravelRequests WHERE Location LIKE '%R'", _
"SELECT * FROM ApprovedTravelRequests WHERE [Last Name] LIKE 'S%'"SELECT * FROM ApprovedTravelRequests WHERE [Last Name] LIKE 'RA%'", _
"SELECT * FROM ApprovedTravelRequests WHERE [Last Name] LIKE '%LAS'", _
"SELECT * FROM ApprovedTravelRequests WHERE [Travel Cost] > 1000", _
"SELECT * FROM ApprovedTravelRequests WHERE [Travel Cost] < 1000", _
"SELECT * FROM ApprovedTravelRequests WHERE [First Name] = 'Janet' And [Last Name] = 'Dunford'", _
"SELECT * FROM ApprovedTravelRequests WHERE [First Name] = 'Janet' Or [Last Name] = 'Tirrell'", _
"SELECT * FROM ApprovedTravelRequests WHERE Location = 'Chicago, Illinois' And [Purpose For Travel] = 'Financial Seminar'", _
"SELECT * FROM ApprovedTravelRequests WHERE Location = 'Chicago, Illinois' Or [Purpose For Travel] = 'Financial Seminar'"}
' Anything in ' ' is case sensitive
' 'R%' brings up locations starting with R,
' %R' brings up locations ending in R,
' %A% brings up locations starting & ending with A
' Use [ ] where a space has been inserted in name
' % is a wildcard - fills in for fuzzy characters
' >= is a relational operator to
' logical operators AND OR to combine fields for search
% is a wild card character - fills in for other characters
Use [ ] where a space has been inserted in name
Anything in quotes is case sensitive
Monday, August 24, 2009
Databases - SQL
SQL = Structured Query Language
* in SQL = ALL
Tool used for data base = DataGridView
Functions: Select, Delete, Update, Insert
Concepts:
ConnectionString
ConnectionObject
CommandObject
DataAdapter
DataSetObject
Remember: PrimaryKey & AutoNumber is a unique identity field
ID IS KING
Specify driver for type of string
* in SQL = ALL
Tool used for data base = DataGridView
Functions: Select, Delete, Update, Insert
Concepts:
ConnectionString
ConnectionObject
CommandObject
DataAdapter
DataSetObject
Remember: PrimaryKey & AutoNumber is a unique identity field
ID IS KING
Specify driver for type of string
Monday, August 17, 2009
Databases
Access Database
SQL - Structured Query Language
Language used for insert, update, select, delete
Creates Reports & Queries
Concept for Project
ConnectionString: The supermarket address
ConnectionObject: The car
CommandObject: The shopping list
DataAdapter: Mum doing the shopping
DataSetObject: Pantry
* in SQL = ALL
SQL - Structured Query Language
Language used for insert, update, select, delete
Creates Reports & Queries
Concept for Project
ConnectionString: The supermarket address
ConnectionObject: The car
CommandObject: The shopping list
DataAdapter: Mum doing the shopping
DataSetObject: Pantry
* in SQL = ALL
Sunday, August 16, 2009
Relational Database Management System - Access
Can create queries & reports from Access Database
Table contains:
Columns are knows as "fields"
Rows contain "records"
Declare the datatype for field
ID is used a lot in databases - if you know the ID, that's all that is needed to know to access a record
ID can be the Primary Key - only one field can be the Primary Key
Table contains:
Columns are knows as "fields"
Rows contain "records"
Declare the datatype for field
ID is used a lot in databases - if you know the ID, that's all that is needed to know to access a record
ID can be the Primary Key - only one field can be the Primary Key
Blog Task
1. What is a data base?
A database is a collection of data that is organised in tables/list about a specific topic that can be easily accessed, managed and updated. Anything that stores lists/tables of data, ie, inventory list.
2. What are the different types of databases?
Flat file database excel spreadsheet.
Relational database, this is a tabular type database in which data is defined so that it can be reorganized and accessed in a number of different ways, eg. lists.
Distributed database database is one that stored on various computers in a network - multiple user, eg. Chisholm.
Object-oriented programming database - works well with object programming languages
A database is a collection of data that is organised in tables/list about a specific topic that can be easily accessed, managed and updated. Anything that stores lists/tables of data, ie, inventory list.
2. What are the different types of databases?
Flat file database excel spreadsheet.
Relational database, this is a tabular type database in which data is defined so that it can be reorganized and accessed in a number of different ways, eg. lists.
Distributed database database is one that stored on various computers in a network - multiple user, eg. Chisholm.
Object-oriented programming database - works well with object programming languages
Monday, August 10, 2009
Ch 9 File Handling
System IO
IO.File
- Creating Files
- Deleting Files
- Moving Files
- Copying Files
- Opening Files
StreamReader - IO.StreamReader
StreamWriter - IO.StreamWriter - has functionality for text
Constructor = On Switch
IO.File
- Creating Files
- Deleting Files
- Moving Files
- Copying Files
- Opening Files
StreamReader - IO.StreamReader
StreamWriter - IO.StreamWriter - has functionality for text
Constructor = On Switch
Subscribe to:
Posts (Atom)