如何生成查询语句?

查询语句的组成部份
返回的字段
排序
分组

返回的字段--->可能是具体表的字段,也可能是一个sql函数,也可能是一个子查询
排序的字段--->可能是具体表的字段,也可能是一个sql函数.
分组的字段--->具体表的字段

所以对于返回的字段和排序的字段都有一个共性.可能提一个公共的接口出来.


    ''' -----------------------------------------------------------------------------
    ''' Project  : Lily.PersistenceLayer1.1
    ''' Interface  : Entity.IField
    '''
    ''' -----------------------------------------------------------------------------
    ''' <summary>
    ''' 获取字段的接口
    ''' </summary>
    ''' <remarks>
    ''' </remarks>
    ''' <history>
    '''  [zqonline] 2006-06-08 Created
    ''' </history>
    ''' -----------------------------------------------------------------------------
    Public Interface IField
        ''' -----------------------------------------------------------------------------
        ''' <summary>
        ''' 获取字段字符串
        ''' </summary>
        ''' <returns></returns>
        ''' <remarks>
        ''' </remarks>
        ''' <history>
        '''  [zqonline] 2006-06-08 Created
        ''' </history>
        ''' -----------------------------------------------------------------------------
        Function ToField(ByVal DataBaseType As DBAccessLayer.DataBaseTypeEnum) As String
    End Interface

posted on 2006-06-08 08:36  zqonline  阅读(291)  评论(0编辑  收藏  举报

导航