Showing posts with label SQL. Show all posts
Showing posts with label SQL. Show all posts

Thursday, February 6, 2014

SQL Sever Datediff() Function to Show Date Difference in Days Hours Minutes


Introduction: Here I will explain datediff() function in SQL Server with example to get date difference in days hours minutes, years, month between two dates or calculate datediff in SQL Server in days hours minutes format. Description: In previous articles I written SQL query to get data between two characters range, Get table size in SQL Server, SQL Server reset identity column to 1 in


I guess you came to this post by searching similar kind of issues in any of the search engine and hope that this resolved your problem. If you find this tips useful, just drop a line below and share the link to others and who knows they might find it useful too.

Stay tuned to my blogtwitter or facebook to read more articles, tutorials, news, tips & tricks on various technology fields. Also Subscribe to our Newsletter with your Email ID to keep you updated on latest posts. We will send newsletter to your registered email address. We will not share your email address to anybody as we respect privacy.


This article is related to

SQL,SQL Server,MS SQL Server.Net,Articles,Computer Tutorials

Wednesday, February 5, 2014

SQL Server Get Data between Two Characters Range Start with A to C


Introduction: Here I will explain how to get data between two characters range in SQL server or get user details start with A-C range in SQL server. Description: In previous articles I explained Acid Properties in SQL Server, Query to get database size in SQL Server, show time difference in minute ago hour ago etc in SQL Server, can function return multiple values in SQL Server and many


I guess you came to this post by searching similar kind of issues in any of the search engine and hope that this resolved your problem. If you find this tips useful, just drop a line below and share the link to others and who knows they might find it useful too.

Stay tuned to my blogtwitter or facebook to read more articles, tutorials, news, tips & tricks on various technology fields. Also Subscribe to our Newsletter with your Email ID to keep you updated on latest posts. We will send newsletter to your registered email address. We will not share your email address to anybody as we respect privacy.


This article is related to

SQL,SQL Server,MS SQL Server.Net,Articles,Computer Tutorials

Thursday, October 24, 2013

10 Easy Steps to a Complete Understanding of SQL


Too many programmers think SQL is a bit of a beast. It is one of the few declarative languages out there, and as such, behaves in an entirely different way from imperative, object-oriented, or even functional languages (although, some say that SQL is also somewhat functional).


I guess you came to this post by searching similar kind of issues in any of the search engine and hope that this resolved your problem. If you find this tips useful, just drop a line below and share the link to others and who knows they might find it useful too.

Stay tuned to my blogtwitter or facebook to read more articles, tutorials, news, tips & tricks on various technology fields. Also Subscribe to our Newsletter with your Email ID to keep you updated on latest posts. We will send newsletter to your registered email address. We will not share your email address to anybody as we respect privacy.


This article is related to

</ span>Articles,Computer Tutorials,Database,SQL

Wednesday, January 9, 2013

Understanding SQL Injection and Creating SQL Injection Proof ASP.NET Applications


As ASP.NET developers, we often write dynamic SQL to perform some database operations. These dynamic SQL is some cases might be created by concatenating strings with user input. If we are not validating the user input and taking every input as is, then this kind of scenario poses a very serious problem of SQL injection.

SQL injection is the attack in which the user of the website will input some SQL code as input which would result in creating a SQL statement that developers didn't intend to write. These SQL statements could result in unauthorized access, revealing secret user information and sometimes it could even wipe out the entire data lying on the server.


✔ Read More...


I guess you came to this post by searching similar kind of issues in any of the search engine and hope that this resolved your problem. If you find this tips useful, just drop a line below and share the link to others and who knows they might find it useful too.

Stay tuned to my blogtwitter or facebook to read more articles, tutorials, news, tips & tricks on various technology fields. Also Subscribe to our Newsletter with your Email ID to keep you updated on latest posts. We will send newsletter to your registered email address. We will not share your email address to anybody as we respect privacy.


This article is related to

Computer Tutorials,Database,SQL,SQL Injection,ASP.Net

Saturday, December 29, 2012

Update Stored Proc with Raw SQL Query via EDF Framework


Update Stored Proc with Raw SQL Query via EDF Framework Introduction Today, in this article let's play around with one of the interesting and most useful concept in EDM Framework.   Question: What is update stored proc with raw SQL query via EDM framework? In simple terms "It provides flexibility to update data with help of raw [...]


I guess you came to this post by searching similar kind of issues in any of the search engine and hope that this resolved your problem. If you find this tips useful, just drop a line below and share the link to others and who knows they might find it useful too. 

Stay tuned to my blogtwitter or facebook to read more articles, tutorials, news, tips & tricks on various technology fields. Also Subscribe to our Newsletter with your Email ID to keep you updated on latest posts. We will send newsletter to your registered email address. We will not share your email address to anybody as we respect privacy.


This article is related to
C#,.NET,Architect,Intermediate,VS2010,.Net,Articles,Computer Tutorials,SQL,SQL Query,EDF,EDF Framework

Wednesday, December 26, 2012

Delete Stored Proc with Raw SQL Query via EDF Framework


Delete Stored Proc with Raw SQL Query via EDF Framework Introduction Today, in this article let's play around with one of the interesting and most useful concept in EDM Framework.   Question: What is deleting stored proc data with raw SQL query via EDM framework? In simple terms "It provides flexibility to delete with help of raw [...]


I guess you came to this post by searching similar kind of issues in any of the search engine and hope that this resolved your problem. If you find this tips useful, just drop a line below and share the link to others and who knows they might find it useful too.

Stay tuned to my blogtwitter or facebook to read more articles, tutorials, news, tips & tricks on various technology fields. Also Subscribe to our Newsletter with your Email ID to keep you updated on latest posts. We will send newsletter to your registered email address. We will not share your email address to anybody as we respect privacy.


This article is related to
Articles,Computer Tutorials,EDF Framework,SQL,Store Procedures

Saturday, November 17, 2012

Self Join using Lambda


Self Join using Lambda

Self Join using Lambda Introduction Today, in this article let's play around with one of the interesting and most useful concept in LINQ.   Question: What isself join using lambda? In simple terms "It provides flexibility to perform join on single table and get the result set based on request query with lambda operation".   Step [...]

Read more of this post

I guess you came to this post by searching similar kind of issues in any of the search engine and hope that this resolved your problem. If you find this tips useful, just drop a line below and share the link to others and who knows they might find it useful too.

Stay tuned to my blogtwitter or facebook to read more articles, tutorials, news, tips & tricks on various technology fields. Also Subscribe to our Newsletter with your Email ID to keep you updated on latest posts. We will send newsletter to your registered email address. We will not share your email address to anybody as we respect privacy.


This article is related to

C#,.NET,Architect,Intermediate,VS2010,.Net,Articles,Computer Tutorials,LINQ,SQL,Joins,SQL Joins,Self Join,Lamba Expression

Self Join using LINQ


Self Join using LINQ

Self Join using LINQ Introduction Today, in this article let's play around with one of the interesting and most useful concept in LINQ.   Question: What isself join using LINQ? In simple terms "It provides flexibility to perform join on single table and get the result set based on request query".   Step 1: Create a new [...]

Read more of this post

I guess you came to this post by searching similar kind of issues in any of the search engine and hope that this resolved your problem. If you find this tips useful, just drop a line below and share the link to others and who knows they might find it useful too.

Stay tuned to my blogtwitter or facebook to read more articles, tutorials, news, tips & tricks on various technology fields. Also Subscribe to our Newsletter with your Email ID to keep you updated on latest posts. We will send newsletter to your registered email address. We will not share your email address to anybody as we respect privacy.


This article is related to
C#,.NET,Architect,Intermediate,VS2010,.Net,Articles,Computer Tutorials,LINQ,SQL,Joins,SQL Joins,Self Join

Sunday, November 11, 2012

What are SQL Joins and How to use thses..



The first thing we learn to do with SQL is writing a SELECT statement to get data from one table. This kind of statement seems to be straightforward and very close to the language we speak.
But real-world queries are often much more sophisticated than those simple SELECT statements.
First of all, usually the data we need is split into several different tables. This is a natural consequence of data normalization, which is an essential feature of any well designed database model. And SQL gives you the power to put that data together.
In the past, DBAs and developers used to put all necessary tables and/or views in the FROM clause and then use theWHERE clause to define how the records from each table would combine with the other records. (To make this text a bit more readable, from now on, I will simplify things and say "table" instead of "table and/or view").


I guess you came to this post by searching similar kind of issues in any of the search engine and hope that this resolved your problem. If you find this tips useful, just drop a line below and share the link to others and who knows they might find it useful too. 


Stay tuned to my blogtwitter or facebook to read more articles, tutorials, news, tips & tricks on various technology fields. Also Subscribe to our Newsletter with your Email ID to keep you updated on latest posts. We will send newsletter to your registered email address. We will not share your email address to anybody as we respect privacy.


This article is related to

Computer Tutorials,Database,SQL,SQL Joins

Tuesday, July 3, 2012

Seeding your Metro style app with a SQLite database


It looks like people are really glad about being able to use SQLite within their Metro style apps. I had written two previous posts (Using SQLite in your Metro style app and HOWTO: Build and include SQLite) about this topic. I'm pleased to report that since those posts the SQLite team released a build (3.7.13 as of the datestamp on this post) which also provides the binary (32- and 64-bit versions) pre-compiled for you for inclusion in your Metro style app. You can get them from the SQLite download page.

I've received a few comments/questions that I thought I might clarify in my own opinion (and some facts) about using SQLite in your app.

Read More from: Original Source


I guess you came to this post by searching similar kind of issues in any of the search engine and hope that this resolved your problem. If you find this tips useful, just drop a line below and share the link to others and who knows they might find it useful too. 

Stay tuned to my blogtwitter or facebook to read more articles, tutorials, news, tips & tricks on various technology fields. Also Subscribe to our Newsletter with your Email ID to keep you updated on latest posts. We will send newsletter to your registered email address. We will not share your email address to anybody as we respect privacy.


Thursday, June 28, 2012

Making Your Own MySQL Backup and Restore Tools in C#/VB.NET/ASP.NET - MySqlBackup.DLL (Supports Unicode, UTF8)


This article introduce a tool (DLL) that can backup/restore MySQL database in .NET Programming Language and some sample codes on how to use it. It is an alternative to MySqlDump.

On the other hand, this tool uses native .NET language to handle all values and parameters, therefore it can handle Unicode/UTF8 character (multi-language) well.

Another benefits of making this tool is, we don't have to rely on two small programs - MySqlDump.exe and MySql.exeto perform the backup and restore task. We will have better control on the output result.

This tool is develop in C# but useable in VB.NET.

The most common way to backup a MySQL Database is by using MySqlDump and MySQL Administrator.

MySQL Administrator is good for developers, but, when comes to client or end-user, the recommended way is to get every parameter preset and all they need to know is press the big button "Backup" and everything is done. Using MySQL Administrator as a backup tool is not a suitable solution for client or end-user.

On the other hand, MySqlDump is another tool that can customize within code to meet specific situation. However, MySqlDump has compatible problems while handling with Unicode characters, for example Korean, Japanese, Chinese and Russian characters. The data will corrupt during the encoding between MySQL database and MySqlDump.  

This tool (MySqlBackup.dll) can helps developer to build the big button "Backup" for end-user (so everything done automatically) and solves the Unicode encoding error that might cause by MySqlDump.

Read More...

I guess you came to this post by searching similar kind of issues in any of the search engine and hope that this resolved your problem. If you find this tips useful, just drop a line below and share the link to others and who knows they might find it useful too. 

Stay tuned to my blogtwitter or facebook to read more articles, tutorials, news, tips & tricks on various technology fields. Also Subscribe to our Newsletter with your Email ID to keep you updated on latest posts. We will send newsletter to your registered email address. We will not share your email address to anybody as we respect privacy.


Tuesday, June 26, 2012

Introduction to NoSQL


For the past several decades, database professionals use a single standard supported by all databases: which is the Structured Query Language (SQL). We've relied upon the table-oriented relational database for all of our data storage and retrieval needs, without thinking about other alternatives. But now time is changing. The NoSQL database model tosses the relational model on its head by abandoning many deeply held beliefs about the "proper" structure for a database. In exchange for removing some of the design constraints, NoSQL databases can achieve enhanced performance flexibility.

Changing the Model

Relational databases have always relied upon some very hard-and-fast, structured rules that govern the conduct of database transactions. These are encoded in the ACID model and require that the database always preserve the some rules which are atomicity, consistency, isolation and durability of database transactions.  Any action that might violate the ACID model is expressly prohibited and there is no way to handle some fuzzy situations. 

NoSQL uses the BASE model and turns the ACID model upside down and allows a much more laissez-faire approach to database management. Instead of requiring strict adherence to the ACID principles, BASE offers three loose rules which are basic availability, soft state and eventual consistency. It's fair to say that NoSQL's BASE approach is the laid-back alternative to the straight-laced ACID model used by relational databases.

If Not Tables, Then What?

Instead of using structured tables to store multiple related attributes in a row, NoSQL databases use the concept of a key/value store. Quite simply, there is no schema for the database. It simply stores values for each provided key, distributes them across the database and then allows their well-organized retrieval. The lack of a schema prevents complex queries and essentially prevents the use of NoSQL as a transactional database environment. 

There are four main types of NoSQL databases:
  1. The basic key/value store performs nothing other than the function described above – taking a binary data object, associating it with a key, and storing it in the database for later retrieval.
  2. Document stores go beyond this slightly by imposing a little more structure on the binary object. The objects must be documents, encoded in some recognizable format, such as XML or PDF, but there are no requirements about the structure or content of the document. Each document is stored as the value portion of a key/value store and may be accompanied by metadata embedded in the document itself.
  3. Columnar databases are a hybrid between NoSQL and relational databases. They provide some row-and-column structure, but do not have the strict rules of relational databases.
  4. Graph databases store information in multi-attribute tuples that reflect relationships in a different way. For example, a graph database might be used to store the "friend" relationships of a social network, with a record merely consisting of two friends who share a relationship.
NoSQL Architecture

The core of the NoSQL database is the hash function – a mathematical algorithm that takes a variable length input and produces a consistent, fixed-length output. The key of each key/value pair being fed to a NoSQL database is hashed and this hash value is used to direct the pair to a particular NoSQL database server, where the record is stored for later retrieval. 

When an application wishes to retrieve a key value pair, it provides the database with the key. This key is then hashed again to determine the appropriate server where the data would be stored (if the key exists in the database) and then the database engine retrieves the key/value pair from that server. 

As you read the description of this process, you may find yourself wondering "How does the user or application perform more advanced queries, such as finding all of the keys that have a particular value or sorting data by a value?" And, there's the rub – NoSQL databases simply do not support this type of functionality. They are designed for the rapid, efficient storage of key/value pairs where the application only needs a place to stash data, later retrieving it by the key, and only by the key. If you need to perform other queries, NoSQL is not the appropriate platform for your use.

Redundancy and Scalability in NoSQL

The simplistic architecture of NoSQL databases is a major benefit when it comes to redundancy and scalability. To add redundancy to a database, administrators simply add duplicate nodes and configure replication between a primary node and its counterpart. Scalability is simply a matter of adding additional nodes. When those nodes are added, the NoSQL engine adjusts the hash function to assign records to the new node in a balanced fashion.

I guess you came to this post by searching similar kind of issues in any of the search engine and hope that this resolved your problem. If you find this tips useful, just drop a line below and share the link to others and who knows they might find it useful too. 

Stay tuned to my blogtwitter or facebook to read more articles, tutorials, news, tips & tricks on various technology fields. Also Subscribe to our Newsletter with your Email ID to keep you updated on latest posts. We will send newsletter to your registered email address. We will not share your email address to anybody as we respect privacy.


LinkWithin

LinkWithin

Like Us On Facebook and Receive All Updates!

You can also receive Free Email Updates:

Powered By Tutorails